<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateClassifyTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('classify', function (Blueprint $table) {
            $table->increments('id');
            $table->string('title');
            $table->integer('two_level')->default(0)->comment('二级分类');
            $table->integer('order')->default(0)->comment('排序');
            $table->integer('is_display')->nullable()->comment('是否显示在导航栏');
            $table->string('keywords')->nullable()->comment('关键字');
            $table->text('description')->nullable()->comment('描述');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('classify');
    }
}
